import math

i = 1 
max = 0
index = 0
with open("p099_base_exp.txt","r") as f:
    for line in f.readlines():
        # print line
        # print type(line)
        x = line.split(",")
        # print x
        res = int(x[1])*math.log(int(x[0]))
        if res > max:
            index = i;
            max = res
        i = i+1
print index,max